<!DOCTYPE html>
<html>

<head>
	<meta charset="UTF-8">
	<title>我邀请的</title>
	<meta name="viewport" content="width=device-width, initial-scale=1.0,user-scalable=no" />
	<meta http-equiv="Access-Control-Allow-Origin" content="*">
	<meta http-equiv="X-UA-Compatible" content="ie=edge" />
	<link rel="stylesheet" href="../css/base.css" />
	<link rel="stylesheet" href="../css/I_invited_personal.css" />
	<script src="../js/jquery-2.2.3.min.js"></script>
	<script type="text/javascript" src="../js/rem.js"></script>
	<script src="../js/common.js"></script>
</head>

<body>
	<div class="header">
		<a href="javascript:history.back(-1)"><img src="../img/g_next.png" alt="" /></a>
		我邀请的
	</div>
	<div style="height: .44rem;"></div>
	<!--<div class="container">-->
		<!--<span class="left-sp">邀请人总人数</span>-->
		<!--<span class="right-sp allpeople">0</span>-->
	<!--</div>-->
	<!--<div class="container" style="margin-bottom: .15rem">-->
		<!--<span class="left-sp">团队总业绩</span>-->
		<!--<span class="right-sp allCash">0</span>-->
	<!--</div>-->
	<ul class="invited_main">

		<!-- <li class="invited_main_li">
				<span class="invited_name">哈哈</span>
				<p class="invited_tel">13315466565</p>
				<img class="invited_xia" src="../img/g_xiala.png" alt="" />
			</li>
			<div class="invited_xinxi">
				<p>分享人数：123人</p>
				<p>消费总额：1000元</p>
			</div>
			<li class="invited_main_li">
				<span class="invited_name">哈哈</span>
				<p class="invited_tel">13315466565</p>
				<img class="invited_xia" src="../img/g_xiala.png" alt="" />
			</li>
			<div class="invited_xinxi">
				<p>分享人数：123人</p>
				<p>消费总额：1000元</p>
			</div>
			<li class="invited_main_li">
				<span class="invited_name">哈哈</span>
				<p class="invited_tel">13315466565</p>
				<img class="invited_xia" src="../img/g_xiala.png" alt="" />
			</li>
			<div class="invited_xinxi">
				<p>分享人数：123人</p>
				<p>消费总额：1000元</p>
			</div> -->
	</ul>
</body>
<script>
        console.log('1111')
        $.ajax({
            url: SURL + '/api/xlsUser/fans',
            dataType: 'json',
            data: {
                userId: localStorage.getItem('userId'),
            },
            type: 'get',
            success: res => {
                var userList = res.data.usersList;
                userList.forEach(element => {

                    $('.invited_main').append(
                        `
						<li class="invited_main_li">
							<span class="invited_name">${element.userName}</span>
							<p class="invited_tel">${element.userPhone}</p>
						</li>
					`
                    )
                });
                $('.invited_xia').click(function () {
                    if ($(this).attr("src") == "../img/g_xiala.png") {
                        $(this).parent().next().show();
                        $(this).attr("src", "../img/g_shangla.png");
                    } else if ($(this).attr("src") == "../img/g_shangla.png") {
                        $(this).parent().next().hide();
                        $(this).attr("src", "../img/g_xiala.png");
                    }
                })
            }
        })
</script>

</html>
